package com.itheima.reggie.service;

import com.itheima.reggie.common.R;
import com.itheima.reggie.entity.Employee;
import com.itheima.reggie.entity.Page;

/**
 * @Author: dw
 * @Date 2022/3/9 14:39
 */
public interface EmployeeService {
    /**
     * 用户登录
     * @param employee
     * @return
     */
    Employee login(Employee employee);

    /**
     * 条件分页查询
     * @param page 当前页
     * @param pageSize 每页数据
     * @param name 条件
     * @return
     */
    Page<Employee> findByPage(Integer page,Integer pageSize,String name);

    /**
     * 添加用户
     * @param employee
     * @return
     */
    boolean save(Employee employee);

    /**
     * 根据id回显页面
     * @param id
     * @return
     */
    Employee findById(Long id);

    /**
     * 修改用户
     * @param employee
     * @return
     */
    boolean update(Employee employee);
}
